package com.gxa.ehome.entity;

import com.alibaba.fastjson.annotation.JSONField;

import java.util.Date;

public class User {
    private Integer id;
    private String name;
    private String phone;
    @JSONField(format = "YYYY-MM-dd")
    private Date brith;
    private String sex;
    @JSONField(format = "YYYY-MM-dd HH:mm:ss")
    private Date regTime;

    public User(){

    }

    public User(Integer id, String name, String phone, Date brith, String sex, Date regTime) {
        this.id = id;
        this.name = name;
        this.phone = phone;
        this.brith = brith;
        this.sex = sex;
        this.regTime = regTime;
    }
    public User( String name, String phone, Date brith, String sex, Date regTime) {

        this.name = name;
        this.phone = phone;
        this.brith = brith;
        this.sex = sex;
        this.regTime = regTime;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public Date getBrith() {
        return brith;
    }

    public void setBrith(Date brith) {
        this.brith = brith;
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    public Date getRegTime() {
        return regTime;
    }

    public void setRegTime(Date regTime) {
        this.regTime = regTime;
    }

    @Override
    public String toString() {
        return "User{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", phone='" + phone + '\'' +
                ", brith=" + brith +
                ", sex='" + sex + '\'' +
                ", regTime=" + regTime +
                '}';
    }
}
